<template>
  <div class="home">
    <!-- 轮播图 -->
    <mt-swipe :show-indicators="false">
      <mt-swipe-item v-for="item in swipe_data" :key="item.uniquekey">
        <a :href="item.url">
          <img :src="item.thumbnail_pic_s" :alt="item.title" />
        </a>
      </mt-swipe-item>
    </mt-swipe>
    <!-- 六宫格 -->
    <ul class="mui-table-view mui-grid-view mui-grid-9">
      <li class="mui-table-view-cell mui-media mui-col-xs-4 mui-col-sm-3">
        <a href="#">
          <img src="/static/liugongge/menu1.png" alt="">
          <div class="mui-media-body">新闻资讯</div>
        </a>
      </li>
      <li class="mui-table-view-cell mui-media mui-col-xs-4 mui-col-sm-3">
        <a href="#">
          <img src="/static/liugongge/menu2.png" alt="">
          <div class="mui-media-body">图片分享</div>
        </a>
      </li>
      <li class="mui-table-view-cell mui-media mui-col-xs-4 mui-col-sm-3">
        <a href="#">
          <img src="/static/liugongge/menu3.png" alt="">
          <div class="mui-media-body">商品购买</div>
        </a>
      </li>
      <li class="mui-table-view-cell mui-media mui-col-xs-4 mui-col-sm-3">
        <a href="#">
          <img src="/static/liugongge/menu4.png" alt="">
          <div class="mui-media-body">留言反馈</div>
        </a>
      </li>
      <li class="mui-table-view-cell mui-media mui-col-xs-4 mui-col-sm-3">
        <a href="#">
          <img src="/static/liugongge/menu5.png" alt="">
          <div class="mui-media-body">视频专区</div>
        </a>
      </li>
      <li class="mui-table-view-cell mui-media mui-col-xs-4 mui-col-sm-3">
        <a href="#">
          <img src="/static/liugongge/menu6.png" alt="">
          <div class="mui-media-body">联系我们</div>
        </a>
      </li>
    </ul>
  </div>
</template>

<script>
export default {
  name: "home",
  data() {
    return {
      swipe_data: null
    };
  },
  created() {
    this.getSwipeData();
  },
  methods: {
    getSwipeData() {
      this.$http.get("/swipe").then(data => {
        this.swipe_data = data.body.result.data;
      });
    }
  }
};
</script>

<style scoped>
.mint-swipe {
  height: 200px;
  z-index: 1;
}
.mint-swipe-items-wrap img {
    width: 100%;
    height: 100%;
}
.mui-table-view{
    
}

.mui-table-view-cell img{
    width: 60px;
}
.mui-media-body{
    height: 20px;
}
</style>